package com.quectel.core.module.resource.dto;

import com.quectel.core.module.device.dto.DeviceCategoryDto;
import com.quectel.core.module.device.dto.DeviceTypeDto;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotBlank;
import java.io.Serializable;
import java.util.Date;
import java.util.List;

/**
 * 资源组表
 *
 * @author rananxin
 * @email: ryan.ran@quectel.com
 * @date 2021-12-08 16:11:40
 */
@Data
@Schema
public class ResourceGroupDto implements Serializable {

    /**
     *
     */
    @Schema(description = "")
    private Long id;

    /**
     * 资源组编码
     */
    @Schema(description = "资源组编码")
    @NotBlank
    @Length(min = 1, max = 80)
    private String code;

    /**
     * 资源组名称
     */
    @Schema(description = "资源组名称")
    private String name;

    /**
     * 备注
     */
    @Schema(description = "备注")
    private String remark;

    /**
     *
     */
    @Schema(description = "")
    private Date createTime;

    /**
     *
     */
    @Schema(description = "")
    private String editor;

    /**
     *
     */
    @Schema(description = "")
    private Date editTime;

    /**
     *
     */
    @Schema(description = "")
    private String creator;

    /************非数据库字段 start ************/

    @Schema(description = "已授权的种类")
    private List<DeviceCategoryDto> deviceCategorys;

    @Schema(description = "已授权的类型")
    private List<DeviceTypeDto> deviceTypes;

    /************非数据库字段 end **************/
}
